﻿#ifndef AUTHCONTROLLER_H
#define AUTHCONTROLLER_H

#include <httpcontroller.h>
using namespace stefanfrings;

class AuthController : public HttpController
{
public:
    AuthController(QObject *parent = nullptr);
    ~AuthController();
    void route(QString path, QString method, HttpRequest &request, HttpResponse &response) override;
private:
    void login(HttpRequest &request, HttpResponse &response);
    void codes(HttpRequest &request, HttpResponse &response);
    void logout(HttpRequest &request, HttpResponse &response);
    void m_register(HttpRequest &request, HttpResponse &response);
};

#endif // AUTHCONTROLLER_H
